/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package serverman;

import java.net.Socket;
import java.util.Hashtable;

/**
 *
 * @author wallis
 */
public class ClientsList {
    private Hashtable<String,Socket> hb_list=new Hashtable<String,Socket>();
    public Boolean AddClient(String key, Socket sk) {
        try {
            if (hb_list.containsKey(key)) {
                hb_list.remove(key);
            }
            hb_list.put(key, sk);
        } catch (Exception ex) {
            return false;
        }
        return true;
    }
    public Socket GetClient(String key)
    {
         return (Socket)hb_list.get(key);
    }
}
